<%-- 
    Document   : buu
    Created on : 25/03/2014, 03:57:22 PM
    Author     : nicardonaa
--%>

<%@page import="com.udistrisisbici.vo.BicicletaVO"%>
<%@page import="java.util.List"%>
<%@page import="com.udistrisisbici.vo.UsuarioVO"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Admin1</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
        <meta name="description" content="Slide Down Box Menu with jQuery and CSS3" />
        <meta name="keywords" content="jquery, css3, sliding, box, menu, cube, navigation, portfolio, thumbnails"/>
        <link rel="shortcut icon" href="../favicon.ico" type="image/x-icon"/>
        <link rel="stylesheet" href="../css/style.css" type="text/css" media="screen"/>
        <style type="text/css">@import "../css/UsuStyle.css";</style>
        <style>
            body{
                background:#333 url(../img/bg.jpg) repeat top left;
                font-family:Arial;
            }
            h1.title{
                text-indent:-9000px;
                background:transparent url(../img/title.png) no-repeat top left;
                width:633px;
                height:69px;
            }
        </style>
    </head>
    <body>
        <div id="envoltura">
            <form class="contact_form" action="../BuscarBici">
                <div class="content">
                    <h1 class="title">Slide Down Box Menu with jQuery and CSS3</h1>
                </div>
                <br>
                <label>Buscar_por_Numero_serie:</label>
                <input type="text" style="text-aling:center" name="buscarserie" size="40" maxlength="11" pattern="[0-9]+" title="Sólo debe ingresar números">
                <br>
                <label>Buscar_por_marca:</label>
                <input type="text" style="text-align:center" name="buscarMarca" size="40" maxlength="15" pattern="[A-Za-z ]+" title="solo string">
                <br>
                <label>Buscar_por_color:</label>
                <input type="text" style="text-align:center" name="buscarColor" size="40" maxlength="30" pattern="[A-Za-z ]+" title="no debe contener números">
                <br>
                <label>Buscar_por_codBarras:</label>
                <input type="text" style="text-align:center" name="buscarCod_barras" size="40" maxlength="20" pattern="[0-9]+" title="solo numeros">
                <br>
                <button class="submit" type="submit">BUSCAR</button>
            </form>
        </div>

        <br>
        <br>

        <%
            List<BicicletaVO> lista = (List<BicicletaVO>) session.getAttribute("ListaBici");
            if (lista != null) {

                out.println("<table class='tablesorter'>");
                out.println("<thead>");
                out.println("<tr>");
                out.println("<th>Numero_serie</th>");
                out.println("<th>marca</th>");
                out.println("<th>color</th>");
                out.println("<th>codBarras</th>");
                out.println("</tr>");
                out.println("</thead>");
                out.println("<tbody>");

                for (int i = 0; i < lista.size(); i++) {
                    out.println("<tr>");
                    out.println("<td>" + lista.get(i).getNumSerie() + "</td>");
                    out.println("<td>" + lista.get(i).getMarca() + "</td>");
                    out.println("<td>" + lista.get(i).getColor() + "</td>");
                    out.println("<td>" + lista.get(i).getCodBarras() + "</td>");
                    out.println("</tr>");
                    
                }
            }
            out.println("</tbody>");
            out.println("</table>");
        %>

    </body>   
</html>

